package com.xhgd.dboselect.service.impl;

import com.xhgd.dboservice.PartMaster;
import com.xhgd.dboselect.mapper.PartMasterMapper;
import com.xhgd.dboselect.service.DboService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.Collections;
import java.util.List;

@Service
public class DboServiceImpl implements DboService{

    @Autowired
    private PartMasterMapper partMasterMapper;

    @Override
    public List<PartMaster> getPartmasterByIndex(Integer partIndex) {
        List<PartMaster> result = partMasterMapper.getPartmasterByIndex(partIndex);
        return result == null ? Collections.emptyList() : result;
    }
}